#pragma once
#include "UtilInclude.h"

class GUI_API CFileEnumJob : public CJobItem
{
public:
	CFileEnumJob(CListBoxEx* pFileList,wstring strPath,list<wstring> *pLstPath,HANDLE hEvent,vector<wstring>*	pVeFilter);
	virtual ~CFileEnumJob(void);

public:
	static void	Lock();
	static void	UnLock();
	static void Stop();

protected:
	virtual void	DoWork(void* pThreadContext);
	virtual void	Abort();

protected:
	CListBoxEx*			m_pFileList;
	wstring				m_strPath;
	list<wstring>*		m_pLstPath;
	HANDLE				m_hEvent;
	vector<wstring>*	m_pVeFilter;

	static  LPCRITICAL_SECTION	m_pCS;
	static	 long m_lCounter;

	static	BOOL m_bStop;
};
